package com.blb.service;

import com.blb.entity.Classification;
import com.baomidou.mybatisplus.extension.service.IService;
import com.blb.entity.Notes;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author yanghao
 * @since 2019-12-21
 */
public interface IClassificationService extends IService<Classification> {
    List<Classification> getAllClassification(String pid,String recycle,String userId);

    List<Classification> getFolderByPid(String id,String recycle);

    List<Notes> getNoteByClassificationId(String classificationId);

    void updateMoveFolder(Classification classification);

    void updateFolderName(Classification classification);

    void updateRecycleById(String recycle,String id);
   /* List<Classification> getAllClassification(String pid);*/

    /**
     * 根据pid查询层级文件夹
     * @param pid
     * @return
     */
    List<Classification> getAllFolder(String pid,String userId,String recycle);

    /**
     * 根据没有父级查找所有笔记
     * @return
     */
    List<Notes> getAllNotes(String userId,String recycle);

    /**
     * 根据id查询笔记
     * @param id
     * @return
     */
    Notes getNoteById(String id);

    /**
     * 根据classification_id查询所有笔记
     * @return
     */
    List<Notes> getAllNotesByClassId(String classificationId,String userId,String recycle);

}
